<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ taglib uri="/struts-tags" 	prefix="s"%>
<%@ include file="/jsp/common/common_head.jsp"%>
<!DOCTYPE HTML>
<html>
<head>
<title>示界港管理平台</title>
<%@ include file="/jsp/common/common_script.jsp"%>
<style type="text/css">
</style>
<script type="text/javascript">
 var g_userId = '<%=session.getAttribute("userId")%>';
 var g_bAdmin = '<%=session.getAttribute("isAdmin")%>';
</script>

</head>
<body>
<table class="queryTable" >
	<tr>
		<td class="queryTitle" width="80px">消息分类</td>
		<td class="queryContent">
					<select id="editNotifyType" name="editNotifyType" class="easyui-combobox" panelHeight="auto" editable="false" style="width: 120px" >
							<option value="0" selected>[不限]</option>
							<option value="1">App普通消息</option>
							<option value="2" >App横幅信息</option>
							<option value="3">App轮播图</option>
							<option value="5">App开机广告</option>
							<option value="7">弹窗广告</option>
							<option value="13">Web轮播图</option>
							<option value="101">App活动广播</option>
							<option value="102">App系统通知</option>
					</select>
		</td>
		<td class="queryTitle" width="68px">标题</td>
		<td class="queryContent">
			<input class="inputText" type="text" id="queryTitleName" style="width: 140px;" />
		</td>
		<td class="queryTitle" width="68px">状态:</td>
		<td class="queryContent"> 
			<select id="queryNotifyState" class="easyui-combobox" panelHeight="auto" 
			style="width:100px"></select>
		</td>
	</tr>
	<tr>
		<td class="queryTitle" width="68px">起始日期</td>
		<td class="queryContent">
			<input id="queryDateStart" class="easyui-datebox" style="width:120px">
		</td>
		<td class="queryTitle" width="68px">截止日期</td>
		<td class="queryContent">
			<input id="queryDateEnd" class="easyui-datebox" style="width:140px">
		</td>
		<td class="queryBtnTd" colspan="2">
			<a href="javascript:void(0)" class="easyui-linkbutton" iconCls="icon-search"  onclick="doQuery()">查询</a>
		</td>
	</tr>
</table>

<table id="tmplGrid"></table>

<div id="notifyDlg" class="easyui-window" title="" closed="true" style="width:428px; height:auto;text-align:center; background: #fff;">
	<div border="false" style="padding-left:20px;">
		<form id="notifyForm"  method="POST">
			<s:hidden name="notifyId" id="notifyId"/>
			<table border="0" class="queryTable" width="95%" height="auto" style="margin-bottom:0px;" id="orderTable">
				<tr>	
					<td class="queryTitle" width="80px">显示顺序</td>
					<td class="queryContent">
						<s:textfield id="notify" name="notify" cssClass="inputText easyui-validatebox" data-options="" onkeyup="value=value.replace(/[^\d]/gi,'')" cssStyle="width:250px"/>
					</td>
				</tr>
			</table>
		</form>
	</div>
	<div style="clear:both;padding-top:10px;margin-bottom:10px;text-align:center;" id="notifyBtn">
		<a class="easyui-linkbutton" iconCls="icon-ok" href="javascript:void(0)" onclick="doUpdNotify()">确定</a>
		<a class="easyui-linkbutton" iconCls="icon-cancel" href="javascript:void(0)" onclick="cancelUpdNotify()">取消</a>
    </div>
</div>
	<div id="editMessage" class="easyui-window" title="" closed="true" style="width:800px; height:600px;text-align:center; background: #fff;">
		<div border="false" style="padding-left:10px;padding-right:10px;">
		 <form id="msgForm"  method="POST">
		 	<s:hidden name="notifyId" id="notifyId"/>
			<table border="0" class="queryTable" width="700px" height="auto"  cellpadding="15" style="margin-bottom:0px;" id="MsgEditTable">
				<tr>
					<td >
						<div style="width: 480px;height:30px;">
							<span>关联用户手机号查询</span>
							<input class="inputText"  type="text" id="queryNotifyMobile" />
							<a href="javascript:void(0)" class="easyui-linkbutton" 
							iconCls="icon-search"  onclick="doQuery3()">手机号查询</a>
						</div>
					</td>
					<td>
						<div style="width: 80px;height:30px;">
							<p id="meg" hidden="hidden" style="color:red;background-color: #dedddd;
							font-family: 'Arial Black'; font-size: 12px;height:20px;margin-top: 0px;margin-bottom: auto;">发送成功</p>
						</div>
					</td>
				</tr>
				<tr>
					<td colspan="2"> 
					<table id="rightGrid" class="easyui-datagrid "
					 title="用户信息"  style="width: 680px;  height="auto"></table></td>
				</tr>
			</table>
		</form>
	</div>
	
	<div style="clear:both;padding-top:10px;margin-bottom:10px;text-align:center;" id="msgBtn">
		<a class="easyui-linkbutton" iconCls="icon-cancel" href="javascript:void(0)" onclick="closeMsgList()">关闭</a>
    </div>
</div>


<div id="editDlg" class="easyui-window" title="" closed="true" style="width:820px; height:510px;text-align:center; background: #fff;">
	<div border="false" style="padding-left:10px;padding-right:10px">
		<form id="editForm"  method="POST">
			<s:hidden name="editStId" id="editStId"/>
			<s:hidden name="editCurType" id="editCurType"/>
			<table border="0" class="queryTable" width="98%" height="auto" style="margin-bottom:0px;" id="editTable">
					
				<tr id="trForEdit">
				</tr>
				<tr>
					<td class="queryTitle" width="100px">消息分类</td>
					<td class="queryContent" >
						<select id="editNotifyUse" name="editTopicUse" class="easyui-combobox" panelHeight="auto" editable="false" style="width: 120px" >
							<option value="1">App普通消息</option>
							<option value="2">App横幅信息</option>
							<option value="3" selected>App轮播图</option>
							<option value="5">App开机广告</option>
							<option value="7">弹窗广告</option>
							<option value="13">Web轮播图</option>
							<option value="101">App活动广播</option>
							<option value="102">App系统通知</option>
						</select>
					</td>
					<td class="queryTitle" width="100px">URL访问方式</td>
					<td class="queryContent" >
						<select id="editEncrypt" name="editEncrypt" class="easyui-combobox" panelHeight="auto" editable="false" style="width: 120px" >
							<option value="0" selected>直接访问</option>
							<option value="1">需加密访问</option>
						</select>
					</td>
				</tr>
				<tr>
					<td class="queryTitle" width="100px">标题</td>
					<td class="queryContent">
						<input class="inputText" type="text" style="width:300px" id="editTopicTitle" maxlength="20" />
					</td>
					<td class="queryTitle" width="100px">展示方式</td>
					<td class="queryContent">
						<select id="editNotifyDisplay"class="easyui-combobox" editable="false" panelHeight="auto" style="width: 120px">
							<option value="0" selected="selected">0默认方式</option>
							<option value="1"> 1APP打开时判断显示</option>
							<option value="2"> 2APP后台进入前台时判断显示</option>
							<option value="3"> 3APP后台进入前台均显示</option>
						</select>
					</td>
				</tr>
				<tr>
					<td class="queryTitle" width="100px">跳转链接</td>
					<td class="queryContent" colspan="3">
						<input class="inputText" type="text" style="width:520px" id="editTopicUrl" />
					</td>
				</tr>
				<tr>
					<td class="queryTitle" width="100px" style="color:red;">嵌入网页链接</td>
					<td class="queryContent" colspan="3">
						<input class="inputText" type="text" style="width:520px" id="editEmbedUrl" disabled="disabled"/>
					</td>
				</tr>
				<tr>
					<td class="queryTitle" width="100px" style="color:red;">弹窗广告宽W:</td>
					<td class="queryContent">
						<input class="inputText" type="text" id="editEmbedW" disabled="disabled"/>
					</td>
					<td class="queryTitle" width="100px" style="color:red;">弹窗广告高H:</td>
					<td class="queryContent">
						<input class="inputText" type="text" id="editEmbedH" disabled="disabled"/>
					</td>
				</tr>
				<tr>
					<td class="queryTitle" width="100px">有效起始日期</td>
					<td class="queryContent" >
						<input id="queryDateStartEdit" class="easyui-datetimebox" data-ptions="required:true,showSeconds:false" style="width:160px">
					</td>
					<td class="queryTitle" width="100px">有效截止日期</td>
					<td class="queryContent" >
						<input id="queryDateEndEdit" class="easyui-datetimebox" style="width:160px">
					</td>
				</tr>
				<tr>
					<td class="queryTitle" width="100px">检测频率</td>
					<td class="queryContent" colspan="3">
						<input class="inputText" type="text" style="width:100px" id="editTopicChkFreq" maxlength="9"/>
						<span style="color:red">秒</span>
						<span style="color:darkgrey">(1小时=3600秒 1天=86400秒)</span>
					</td>
				</tr>
				<tr>	
					<td class="queryTitle" width="100px">消息内容</td>
					<td class="queryContent" colspan="3">
						<textarea id="editTopicDesc" name="editTopicDesc" maxlength="100" rows="5" cols="55" class="inputText easyui-validatebox" style="width:100%;resize:none;" data-options="required:true,validType:['maxLength[100]']"></textarea>
					</td>
				</tr>
				<tr>
					<td class="queryTitle" width="100px" height="100px">主题配图</td>
					<td class="queryContent" colspan="2">
						<div style="display:table;text-align:center;height:100px;width:200px">
	        				<span style="display:table-cell;vertical-align:middle" id="topicImg">
	        				</span>
	        			</div>
					</td>
					<td class="queryContent">
						<a class="easyui-linkbutton" id="selFiles" href="javascript:void(0)" >选择图像</a>
					</td>
				</tr>
			</table>
		</form>
	</div>
	<div style="clear:both;padding-top:10px;margin-bottom:10px;text-align:center;" id="editBtn">
		<a class="easyui-linkbutton" iconCls="icon-ok" href="javascript:void(0)" onclick="doEdit()">保存</a>
		<a class="easyui-linkbutton" iconCls="icon-cancel" href="javascript:void(0)" onclick="cancelEdit()">取消</a>
    </div>
</div>
<script type="text/javascript" src="${ctx }/js/qiniu/plupload/plupload.full.min.js"></script>
<script type="text/javascript" src="${ctx }/js/qiniu/plupload/i18n/zh_CN.js"></script>
<script type="text/javascript" src="${ctx}/js/tg/uploadcom.js"></script>
<script type="text/javascript" src="${ctx}/js/tg/ajaxupload.js"></script>
<script type="text/javascript" src="${ctx}/js/tg/notifyInfo.js"></script>
<script type="text/javascript" src="${ctx}/js/encrypt/encrypted-min.js"></script>
</body>
</html>
